package cn.cheegon.blog.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.io.Serializable;
import java.time.LocalDateTime;

import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.Getter;
import lombok.Setter;

/**
 * <p>
 * 博客表
 * </p>
 *
 * @author cheegon
 * @since 2024-06-26
 */
@Getter
@Setter
@TableName("cms_blog")
@Tag(name = "CmsBlog对象", description = "博客表")
public class CmsBlog implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @Schema(description = "点赞数")
    @TableField("appreciation")
    private Long appreciation;

    @Schema(description = "点赞 1是 0否")
    @TableField("commentabled")
    private Integer commentabled;

    @Schema(description = "内容(md)")
    @TableField("content")
    private String content;

    @Schema(description = "内容(html)")
    @TableField("html")
    private String html;

    @Schema(description = "描述")
    @TableField("description")
    private String description;

    @Schema(description = "封面图")
    @TableField("first_picture")
    private String firstPicture;

    @TableField("flag")
    private String flag;

    @Schema(description = "是否发布 1是 0否")
    @TableField("published")
    private Integer published;

    @Schema(description = "推荐 1是 0否")
    @TableField("recommend")
    private Integer recommend;

    @Schema(description = "是否分享 1是 0否")
    @TableField("share_statement")
    private Integer shareStatement;

    @TableField("title")
    private String title;

    @Schema(description = "查看人数")
    @TableField("views")
    private Integer views;

    @TableField("type_id")
    private Long typeId;

    @Schema(description = "发布者id")
    @TableField("user_id")
    private Long userId;

    @Schema(description = "创建时间")
    @TableField("create_time")
    private LocalDateTime createTime;

    @Schema(description = "更新时间")
    @TableField("update_time")
    private LocalDateTime updateTime;
}
